import request from '@/utils/request'

export function showSponsorList(query) {
  return request({
    url: '/sponsor/show',
    method: 'get',
    params: query
  })
}

export function deleteSponsor(sponsorId) {
  return request({
    url: '/sponsor/remove',
    method: 'get',
    params: { 'sponsorId': sponsorId }
  })
}

export function toggleDisplay(data) {
  return request({
    url: '/sponsor/display',
    method: 'post',
    data
  })
}

export function saveSponsor(data) {
  return request({
    url: '/sponsor/save',
    method: 'post',
    data
  })
}

export function updateRank(data) {
  return request({
    url: '/sponsor/rank',
    method: 'post',
    data
  })
}

export function getSponsor(query) {
  return request({
    url: '/sponsor/get',
    method: 'get',
    params: query
  })
}

